package 天梯赛.A.B;

import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int a = scanner.nextInt();
        int b = scanner.nextInt();
        int c = a + b;
         long x=1;
        for (int i = 1; i <=c ; i++) {
            x=x*i;
        }

        System.out.println(x);
    }
}
